<template>
    <div class="detail_module_panel personal_info">
        <h3 id="personal_info" class="detail_panel_title detail_panel_title_icon personal_info_icon">
            {{$t('pageTitle.userInformation')}}</h3>
        <div class="panel_info_content">
            <el-table :data="userData" style="width: 100%">
                <!-- 手机号 -->
                <el-table-column align="left" prop="phone" width="180" :label="$t('common.mobileNumber')"></el-table-column>
                <!--所属APP-->
                <el-table-column prop="appName" :label="$t('common.ownedApp')" min-width="120"></el-table-column><!--所属APP-->
                <el-table-column prop="productName" :label="$t('finance.productName')" min-width="180"></el-table-column><!--产品名-->
                <!-- 姓名 -->
                <el-table-column align="left" :label="$t('common.name')" prop="name" width="180"></el-table-column>
                <!--营销类型-->
                <el-table-column prop="marketingType" :label="$t('salesManage.marketingType')" min-width="120">
                    <template slot-scope="{ row }">{{ keyMap.marketingType(row.marketingType) }}</template>
                </el-table-column><!--营销类型-->
                <!--优惠券-->
                <el-table-column prop="couponUrl" :label="$t('common.coupons')" min-width="180">
                    <template slot-scope="{ row }">{{!row.couponUrl?'--':row.couponUrl}}</template>
                </el-table-column><!--优惠券-->
                <!-- 备注 -->
                <el-table-column prop="recordRemark" :label="$t('common.remark')" min-width="80" :show-overflow-tooltip="true">
                    <template slot-scope="{ row }">{{row.recordRemark ? row.recordRemark : '--' }}</template>
                </el-table-column>
                <!--分派时间-->
                <el-table-column prop="distributionTime" :label="$t('tel.timeDispatch')" min-width="170">
                    <template slot-scope="{row}">{{ row.distributionTime | formatDate('yyyy-MM-dd hh:mm:ss') }}</template>
                </el-table-column><!--分派时间-->
            </el-table>
        </div>
    </div>
</template>

<script>
    import keyMap from '@/config/key-map';

    export default {
        name: 'personalInfo',
        props: {
            userData: {
                type: Array
            }
        },
        data() {
            return {
                keyMap,
            };
        },
    };
</script>

<style lang="scss" scoped>
    .blue {
        margin-left: 10px;
        color: #1983fa;
        font-weight: bold;
    }

    .link_color {
        color: #1983fa;
    }
</style>
